
 <nav class="navbar navbar-expand-lg navbar-dark">

    <div class="collapse navbar-collapse justify-content-left">
      <ul class="navbar-nav mb-2 mb-lg-0 nav-links">

          <!-- Главная -->
          
          <li class="nav-item ps-3">
            <a href="/" class="nav-link active" style="display: flex; align-items: center; padding: 0;">
              <img src="../../media/media/logo.png" alt="" class="" style="max-height: 40px; margin-right: 8px;">  
              Еда в сравнении™
            </a>    
          </li>      
          {% if request.get_full_path == '/' %}
            <li class="nav-item ps-3">
                <a class="nav-link active" aria-current="page" href="/">Главная</a>
            </li>
          {% else %}
            <li class="nav-item ps-3">
                <a class="nav-link" aria-current="page" href="/">Главная</a>
            </li>
          {% endif %}

          <!-- Вся еда -->
          {% if request.get_full_path == '/food/' %}
            <li class="nav-item">
                <a class="nav-link active" aria-current="page" href="/food/">Вся еда</a>
            </li>
          {% else %}
            <li class="nav-item">
                <a class="nav-link" aria-current="page" href="/food/">Вся еда</a>
            </li>
          {% endif %}

          <!-- Любимая еда -->
          {% if user.is_authenticated %}
              {% if request.get_full_path == '/like/page/' %}
                <li class="nav-item">
                    <a class="nav-link active" aria-current="page" href="/like/page/">Любимая еда</a>
                </li>
              {% else %}
                <li class="nav-item">
                    <a class="nav-link" aria-current="page" href="/like/page/">Любимая еда</a>
                </li>
              {% endif %}

              {% if request.get_full_path == '/food/statistics/' %}
                <li class="nav-item">
                  <a href="/food/statistics/" class="nav-link active">Рейтинг еды</a>
                </li>
              {% else %}
                <li class="nav-item">
                  <a href="/food/statistics/" class="nav-link">Рейтинг еды</a>
                </li>
              {% endif %}
          {% endif %}

          <!-- Добавить еду -->
          {% if user.is_authenticated %}
              {% if request.get_full_path == '/food/creation/' %}
                <li class="nav-item">
                    <a class="nav-link active" aria-current="page" href="/food/creation/">Добавить еду</a>
                </li>
              {% else %}
                <li class="nav-item">
                    <a class="nav-link" aria-current="page" href="/food/creation/">Добавить еду</a>
                </li>
              {% endif %}
          {% endif %}

          <!-- Сравнение -->
          {% if user.is_authenticated %}
              {% if request.get_full_path == '/comprasion/page/' %}
                <li class="nav-item">
                    <a class="nav-link active" aria-current="page" href="/comprasion/page/">Сравнение</a>
                </li>
              {% else %}
                <li class="nav-item">
                    <a class="nav-link" aria-current="page" href="/comprasion/page/">Сравнение</a>
                </li>
              {% endif %}
          {% endif %}

          <!-- Отзывы -->
          {% if user.is_authenticated %}
              {% if request.get_full_path == '/comments/' %}
                <li class="nav-item">
                    <a class="nav-link active" aria-current="page" href="/comments/">Отзывы</a>
                </li>
              {% else %}
                <li class="nav-item">
                    <a class="nav-link" aria-current="page" href="/comments/">Отзывы</a>
                </li>
              {% endif %}
          {% endif %}

          <!-- Выйти -->
          {% if user.is_authenticated %}
              <li class="nav-item">
                <a class="nav-link" aria-current="page" href="{% url 'logout' %}">Выйти</a>
              </li>
          {% else %}
              <!--Регистрация-->
              {% if request.get_full_path == '/accounts/register/' %}
                <li class="nav-item">
                  <a class="nav-link active" aria-current="page" href="{% url 'django_registration_register' %}">Регистрация</a>
                </li>
              {% else %}
                <li class="nav-item">
                  <a class="nav-link" aria-current="page" href="{% url 'django_registration_register' %}">Регистрация</a>
                </li>
              {% endif %}

              <!--Войти-->
              {% if request.get_full_path == '/accounts/login/' %}
                <li class="nav-item">
                  <a class="nav-link active" aria-current="page" href="{% url 'login' %}">Войти</a>
                </li>
              {% else %}
                <li class="nav-item">
                  <a class="nav-link" aria-current="page" href="{% url 'login' %}">Войти</a>
                </li>
              {% endif %}
          {% endif %}

          <!-- Профиль -->
          {% if user.is_authenticated %}
              {% if request.get_full_path == '/profile/page.html' %}
                  <li class = "profile float-right">
                      <a class="nav-link active" aria-current="page" href="{% url 'profile_page' %}">Профиль</a>
                      <img class = "ava" src="">
                  </li>
              {% else %}
                  <li class = "profile ">
                      <a class="nav-link" aria-current="page" href="{% url 'profile_page' %}">Профиль</a>
                      <img class = "ava" src="">
                  </li>
              {% endif %}
          {% endif %}
      </ul>
    </div>

</nav>
</body>
</html>